package br.com.viewcar.web.bean;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import br.com.viewcar.entity.Permissao;
import br.com.viewcar.service.PermissaoService;

@Scope("session")
@Component("permissaoBean")
public class PermissaoBean extends EntityBean<Integer, Permissao> {

	@Autowired
	private PermissaoService service;

	protected Integer retrieveEntityId(Permissao entity) {

		return entity.getId();
	}

	protected PermissaoService retrieveEntityService() {

		return this.service;
	}

	protected Permissao createNewEntity() {

		return new Permissao();
	}
}